﻿@using VirtualPress.Infrastructure.Entities.Entity;
@{
    ViewBag.Title = "会议详情编辑";
    Layout = "/Areas/WorkSpace/Views/Shared/_WorkSpace.cshtml";
    Meeting meeting = ViewBag.Meeting;
}
<div id="content-header">
    <h1>
        新增会议</h1>
</div>
<div id="breadcrumb">
    <a href="/WorkSpace/Home" class="tip-bottom"><i class="icon-home"></i>起始页</a> 
    <a href="/WorkSpace/Press/MeetingsApply">会议管理</a> <a href="javascript:"
            class="current">会议编辑</a>
</div>
<div class="container-fluid">
    <div class="row-fluid">
        <div class="span12">
            <div class="widget-box">
                <div class="widget-title">
                    <span class="icon"><i class="icon-pencil"></i></span>
                    <h5>
                        新增会议</h5>
                    <h5 style="float: right; color: Red;">
                        *为必填</h5>
                </div>
                <div class="widget-content nopadding">
                    <form id="form-wizard" class="form-horizontal" method="post" 
                    enctype="multipart/form-data"
                    action="/WorkSpace/Press/EditForMeeting">
                    <input type="hidden" name="id" value="@meeting.Id" />
                    <div id="form-wizard-1" class="step">
                        <div class="control-group">
                            <label class="control-label">
                                会议名称 (*)</label>
                            <div class="controls">
                                <input readonly="readonly"  id="name" type="text" name="Name" 
                                value="@meeting.Name"
                                class="{ required: true, minlength: 2, maxlength: 128, normalchat: true }" />
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                会议缩写 (*)</label>
                            <div class="controls">
                                <input readonly="readonly" id="shortname" type="text" name="ShortName"
                                value="@meeting.ShortName"
                                class="{required: true, minlength: 2, maxlength: 128 }" />
                                <label>
                                    * 用于期刊稿件编号，请认真填写</label>
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                管理员账号 (*)</label>
                            <div class="controls">
                                <input readonly="readonly"  id="txtAdmin" type="text" name="Admin" 
                                value="@meeting.Admin" />
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                行业分类 (*)</label>
                            <div class="controls">
                                <select id="sltIndType" name="IndType">
                                </select>
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                编辑部邮箱 (*)</label>
                            <div class="controls">
                                <input id="txtEmail" type="text" name="Email" class="{required:true,email:true}"
                                 value="@meeting.Email" />
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                主办单位 (*)</label>
                            <div class="controls">
                                <input id="txtZBDW" type="text" name="ZBDW" class="{required:true}" value="@meeting.ZBDW" />
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                新会议Logo</label>
                            <div class="controls">
                                <input id="txtLogo" type="file" name="Logo" />
                                如果不更新Logo请不要选择
                            </div>
                        </div>   
                        <div class="control-group">
                            <label class="control-label">
                                个性化样式</label>
                            <div class="controls">
                                <textarea id="txtcss" name="Css" cols="20" rows="10">@meeting.Css</textarea>
                            </div>
                        </div> 
                    </div>
                    <div class="form-actions">
                        <input id="back" class="btn btn-primary" type="reset" />
                        <input id="next" class="btn btn-primary" type="submit" />
                        <div id="status">
                        </div>
                    </div>
                    <div id="submitted">
                    </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>
@section tail
{
    <script type="text/javascript" src="/scripts/jquery.validate.js"></script>
    <script type="text/javascript" src="/scripts/unicorn.wizard.js"></script>
    <script type="text/javascript" src="/scripts/jquery.metadata.js"></script>
    <script type="text/javascript" src="/scripts/jquery.wizard.js"></script>
    <script type="text/javascript" src="/Scripts/plug.js"></script>
    <script type="text/javascript" charset="utf-8" src="/Scripts/UEditor/editor_config.js"></script>
    <script type="text/javascript" charset="utf-8" src="/Scripts/UEditor/editor_all_min.js"></script>
    <script type="text/javascript">
        $(function () {
            $('#likmeeting').addClass('open active');
            new plug.Control().BuildSelect({ element: 'sltIndType', defaultvalue: '@((int)meeting.IndType)' }, 'profession');
        });
        UE.getEditor('txtAbstract');
        function changeType(sender) {
            var type = $(sender).val();
            if (type == '1') {
                $('#sltIndType').val(0);
                $('#sltIndType').removeAttr('disabled');
            }
            else {
                $('#sltIndType').val(9999);
                $('#sltIndType').attr('disabled', 'disabled');
            }
        }
    </script>
}
